﻿using System;
using System.Collections.Generic;
using System.Text;

namespace IceDog.DNL.CSharp.DesignPattern.DecoratorPattern.ShapeWrapper
{
    public abstract class ShapeDecorator:IShapeAction
    {
        protected ShapeDecorator(IShapeAction shape)
        {
            DecoratedShape = shape;
        }

        protected IShapeAction DecoratedShape { get; set; }

        /// <summary>
        /// 绘制图形
        /// </summary>
        public virtual void Draw()
        {
            DecoratedShape.Draw();
        }
    }
}
